package com.king.hrmsdev.controller;


import com.alibaba.fastjson.JSONObject;
import com.king.hrmsdev.pojo.ReportSalary;
import com.king.hrmsdev.pojo.employee_check;
import com.king.hrmsdev.pojo.employee_counts;
import com.king.hrmsdev.pojo.employee_salary;
import com.king.hrmsdev.service.ReportService;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * @Auther:SnakeKing
 * @Date: 2019-09-22
 * @Description: com.king.hrmsdev.controller
 * @version:1.0
 */
@RestController
public class ReportController {

    @Resource
    private ReportService reportService;

    @RequestMapping(value = "/getEmployeecounts",method=RequestMethod.POST)
    public List<employee_counts> getEmployeecounts() {
        List<employee_counts> result= reportService.depart_employee_count();
        return  result;
    }

    @RequestMapping(value = "/getEmployeesalary",method=RequestMethod.POST)
    public List<employee_salary> getEmployeesalary() {
        List<employee_salary>  result= reportService.depart_employee_salary();
        return  result;
    }

    @RequestMapping(value = "/getEmployeesalaryTop5",method=RequestMethod.POST)
    public List<ReportSalary> getEmployeesalaryTop5() {
        List<ReportSalary>  result= reportService.employee_salaryTop5();
        return  result;
    }


    @RequestMapping(value = "/getEmployeecheck",method=RequestMethod.POST)
    public List<employee_check> getEmployeecheck() {
        List<employee_check>  result= reportService.employee_echeck();
        return  result;
    }





}

